﻿// Original author contact info: Owen Emlen (owene_1998@yahoo.com)
// Note: other individuals may also have contributed to this code
// Project hosted on CodePlex.com as of 1/10/2009 at http://wpfimageviewer.codeplex.com
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Drawing;
using System.Drawing.Imaging;
using System.Threading;
using System.Windows.Media.Imaging;
using AForge.Imaging;
using AForge.Imaging.Filters;
using BrainTechLLC;
using BrainTechLLC.ThreadSafeObjects;

namespace BrainTechLLC.FilterExtensions
{
    public static class DefaultFilterCollections
    {
        public static FilterCollection _fc;
        public static FilterCollection _fcBlur;
        public static FilterCollection _fcBlur2;

        public static FilterCollection CreateDefaultCompareFilters()
        {
            var fc = new FilterCollection();

            List<SingleFilter> list1 = new List<SingleFilter>();
            {
                list1.Add(new SingleFilter(new HistogramEqualization()));
                list1.Add(new SingleFilter(new SaturationCorrection()));
                list1.Add(new SingleFilter(new BrightnessCorrection()));
                list1.Add(new SingleFilter(new Pixellate()));
            }

            list1.ForEach((v) => fc.AddFilter(v));
            return fc;
        }

        public static FilterCollection CreateDefaultBlur1Filters()
        {
            var fc = new FilterCollection();

            List<SingleFilter> list1 = new List<SingleFilter>();
            {
                list1.Add(new SingleFilter(new Blur()));
                list1.Add(new SingleFilter(new Sharpen()));
                list1.Add(new SingleFilter(new HistogramEqualization()));
            }

            list1.ForEach((v) => fc.AddFilter(v));
            return fc;
        }

        public static FilterCollection CreateDefaultBlur2Filters()
        {
            var fc = new FilterCollection();

            List<SingleFilter> list1 = new List<SingleFilter>();
            {
                list1.Add(new SingleFilter(new HistogramEqualization()));
            }

            list1.ForEach((v) => fc.AddFilter(v));
            return fc;
        }
    }
}
